package com.intelligent.mts.client.core.view;

import com.intelligent.mts.client.utils.GBC;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
import javax.swing.*;
import java.awt.*;

/**
 * Created by Garen.Pang on 2016/8/19.
 */
@Component
public class BomPanel extends JPanel{

    @Autowired
    private BomManagePanel bomManagePanel;

    @Autowired
    private BomPNPanel bomPNPanel;

    @Autowired
    private BomSearchPanel bomSearchPanel;

    @Autowired
    private MainStatusPanel mainStatusPanel;

    @PostConstruct
    private void initComponents() {
        this.setLayout(new GridBagLayout());
        this.setPreferredSize(new Dimension(600, 418));

        this.add(bomSearchPanel, new GBC(0,0).setFill(GBC.BOTH).setInsets(5,5,5,0));   //.setWeight(200, 1)
        this.add(bomManagePanel, new GBC(0,1).setFill(GBC.BOTH).setInsets(5,5,5,0));   //.setWeight(200, 1)
        this.add(bomPNPanel, new GBC(0, 2).setFill(GBC.BOTH).setInsets(5,5,5,0));   //.setWeight(200, 15)
        this.add(new JPanel(), new GBC(0, 3).setFill(GBC.BOTH).setWeight(100, 500));

    }
}
